// 配置路由相关的信息
import VueRouter from 'vue-router'
import Vue from 'vue'

import HelloWorld from '../components/HelloWorld'
import Shares from '../components/Shares'
import Hygg from '../components/Hygg'
import GdChange from '../components/GdChange'
import SharesReview from '../components/SharesReview'
import Gzshares from '../components/Gzshares'
import LatelyShares from '../components/LatelyShares'
import Zjlx from '../components/Zjlx'
import Zjlx_bk from '../components/Zjlx_bk'
import Zjlx_gn from '../components/Zjlx_gn'
import Sshy from '../components/Sshy'
import Yjyg from '../components/Yjyg'
import Yjbg from '../components/Yjbg'
import DataChange from '../components/DataChange'
import HintNum from '../components/HintNum'
import HintShares from '../components/HintShares'

// 1.通过Vue.use(插件), 安装插件
Vue.use(VueRouter)

// 2.创建VueRouter对象
const routes = [
    {
        path: '',
        // redirect重定向
        redirect: '/shares'
    },
    {
        path: '/helloworld',
        component: HelloWorld
    },
    {
        path: '/shares',
        component: Shares
    },
    {
        path: '/hygg',
        component: Hygg
    },
    {
        path: '/gdChange',
        component: GdChange
    },
    {
        path: '/sharesReview',
        component: SharesReview
    },
    {
        path: '/gzshares',
        component: Gzshares
    },
    {
        path: '/latelyShares',
        component: LatelyShares
    },
    {
        path: '/zjlx',
        component: Zjlx
    },
    {
        path: '/zjlx_bk',
        component: Zjlx_bk
    },
    {
        path: '/zjlx_gn',
        component: Zjlx_gn
    },
    {
        path: '/sshy',
        component: Sshy
    },
    {
        path: '/yjyg',
        component: Yjyg
    },
    {
        path: '/yjbg',
        component: Yjbg
    },
    {
        path: '/dataChange',
        component: DataChange
    },
    {
        path: '/hintNum',
        component: HintNum
    },
    {
        path: '/hintShares',
        component: HintShares
    }
]
const router = new VueRouter({
    // 配置路由和组件之间的应用关系
    routes,
    mode: 'history',
    linkActiveClass: 'active'
})

// 3.将router对象传入到Vue实例  导出
export default router